﻿@{
    ViewBag.Title = "AddNode";
    Layout = "~/Views/Shared/_JuiLayout.cshtml";

    string pid = MyRequest.GetQueryString("pid");
    string hostId = MyRequest.GetQueryString("hostId");

    Dictionary<string, object> dic_class = CommonBLL.GetModel("Sys_IBClasses", "*", Convert.ToInt32(hostId));

    string className = dic_class["Name"].ToString();
    className = className.Length >= 15 ? className.Substring(0, 15) : className;

    string pidName = selectControlBLL.getNameById("id", pid, "Sys_IBDD", "name");
}

@section header {}
<div id="layout" class="noNavTab">
    <div id="navTab">
        <h2 class="contentTitle">
            添加数据字典项</h2>
        @{
            string rturl = "/SysMenu/List?menu=SysIBDDs&name=list&hostId=" + hostId;
            using (Html.BeginForm("Add", "OperateTotal", new { name = DencryptHelper.Encrypt("Sys_IBDD"), url = rturl }, FormMethod.Post, new { @class = "pageForm required-validate", onsubmit = "return validateCallback(this,navTabAjaxDone)" }))
            { 
            <div class="pageFormContent nowrap">
                <dl>
                    <dt>所属上级：</dt>
                    <dd>
                        @Html.TextBox("PId", pidName, new { @class = " textInput", maxlength = "25", @readonly = "true" })
                        @Html.Hidden("t0_PId", pid, new { @class = "required textInput", maxlength = "25" })
                    </dd>
                </dl>
                <dl>
                    <dt>所属类别：</dt>
                    <dd>
                        @Html.TextBox("ClassId", className, new { @class = " textInput", maxlength = "25", @readonly = "true" })
                        @Html.Hidden("t0_ClassId", hostId, new { @class = "required textInput", maxlength = "25" })
                    </dd>
                </dl>
                <dl>
                    <dt>编码：</dt>
                    <dd>
                        @Html.TextBox("t0_No","", new { @class = " textInput", maxlength = "25" })
                    </dd>
                </dl>
                <dl>
                    <dt>名称：</dt>
                    <dd>
                        @Html.TextBox("t0_Name", "", new { @class = "required textInput", maxlength = "25" })
                    </dd>
                </dl>
                <dl>
                    <dt>描述：</dt>
                    <dd>
                        @Html.TextArea("t0_Description", "", new { @class = " textInput", rows = "5", cols = "80", maxlength = "100" })
                    </dd>
                </dl>
                <dl>
                    <dt>序号：</dt>
                    <dd>
                        @Html.TextBox("t0_SortOrder", "", new { @class = "required textInput digits", maxlength = "25" })
                    </dd>
                </dl>
                <dl>
                    <dt>
                    @dic_class["ValueName1"]：
                    </dt>
                    <dd>
                        @Html.TextArea("t0_Value1", "", new { @class = " textInput", rows = "5", cols = "80", maxlength = "100" })
                    </dd>
                </dl>
                <dl>
                    <dt>
                    @dic_class["ValueName2"]：
                    </dt>
                    <dd>
                        @Html.TextArea("t0_Value2", "", new { @class = " textInput", rows = "5", cols = "80", maxlength = "100" })
                    </dd>
                </dl>
                <dl>
                    <dt>
                    @dic_class["ValueName3"]：
                    </dt>
                    <dd>
                        @Html.TextArea("t0_Value3", "", new { @class = " textInput", rows = "5", cols = "80", maxlength = "100" })
                    </dd>
                </dl>
                <dl>
                    <dt>
                    @dic_class["ValueName4"]：
                    </dt>
                    <dd>
                        @Html.TextArea("t0_Value4", "", new { @class = " textInput", rows = "5", cols = "80", maxlength = "100" })
                    </dd>
                </dl>
                <dl>
                    <dt>&nbsp</dt>
                    <dd>
                        <div class="buttonActive">
                                <div class="buttonContent">
                                    <button type="submit">
                                        添加</button></div>
                            </div>
                    </dd>
                    <dd>
                        <a class="button" href='@rturl'><span>返回</span></a></dd>
                </dl>
            </div>
            }
        }
    </div>
</div>

<link href="../../content/jui-normal.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="/Scripts/pager.js"></script>
<script type="text/javascript">
    $(function () {

    });
</script>
